<script language="JavaScript" type="text/javascript">
function getURLParam(strParamName){
  var strReturn = "";
  var strHref = window.location.href;
  if ( strHref.indexOf("?") > -1 ){
    var strQueryString = strHref.substr(strHref.indexOf("?")).toLowerCase();
    var aQueryString = strQueryString.split("&");
    for ( var iParam = 0; iParam < aQueryString.length; iParam++ ){
      if (
aQueryString[iParam].indexOf(strParamName.toLowerCase() + "=") > -1 ){
        var aParam = aQueryString[iParam].split("=");
        strReturn = aParam[1];
        break;
      }
    }
  }
  return unescape(strReturn);
}

function clabelFilterAction()
{
 
  window.location.href = 
  "conversationlist.html?datasetId=1" +
    "&clabelId=" + document.clabelFilterForm.clabelFilterSelector.options[document.clabelFilterForm.clabelFilterSelector.selectedIndex].value;  

}
 
function initClabelFilter()
{
  var clabelIdParam = getURLParam("clabelId");
  for (i = 0; i < document.clabelFilterForm.clabelFilterSelector.length; i++)
  {
    var option = document.clabelFilterForm.clabelFilterSelector.options[i];
    if (option.value == clabelIdParam)
    {      
      document.clabelFilterForm.clabelFilterSelector.selectedIndex = option.index;
    } else {
          // document.clabelFilterForm.clabelFilterSelector.selectedIndex = 0;
    }
  }
 } 
</script>
 